<%= form_for(resource, :as => resource_name, :url => session_path(resource_name), :html => { :class => 'form-horizontal' }) do |f| %>
<fieldset>
  <legend>Sign in</legend>

  <div class="control-group">
    <%= f.label :email, :class => 'control-label' %>
    <div class="controls">
      <%= f.email_field :email, :class => 'text_field' %>
    </div>
  </div>

  <div class="control-group">
    <%= f.label :password, :class => 'control-label' %>
    <div class="controls">
      <%= f.password_field :password, :class => 'text-field' %>
    </div>
  </div>

  <% if devise_mapping.rememberable? -%>
  <div class="control-group">
    <div class='controls'>
      <label for="user_remember_me" class="checkbox">
        <%= f.check_box :remember_me %> Remember me
      </label>
    </div>
  </div>
  <% end %>

  <div class="form-actions">
    <%= f.submit "Sign in", :class => 'btn btn-primary' %>
  </div>
</fieldset>
<% end -%>
<%= render "devise/shared/links" %>
